package com.by.entity.dto;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;

@Data
@ApiModel("会员注册请求")
public class MemberRegisterDTO {
//    @NotBlank(message = "用户名不能为空")
//    @Size(min = 4, max = 20, message = "用户名长度4-20个字符")
    @ApiModelProperty(value = "用户名", required = true)
    private String username;

//    @NotBlank(message = "密码不能为空")
//    @Size(min = 6, max = 20, message = "密码长度6-20个字符")
    @ApiModelProperty(value = "密码", required = true, example = "123456")
    private String password;

//    @NotBlank(message = "确认密码不能为空")
    @ApiModelProperty(value = "确认密码", required = true, example = "123456")
    private String confirmPassword;

//    @NotBlank(message = "手机号不能为空")
//    @Pattern(regexp = "^1[3-9]\\d{9}$", message = "手机号格式不正确")
    @ApiModelProperty(value = "手机号", required = true, example = "13800138000")
    private String mobile;

    @ApiModelProperty(value = "会员昵称", example = "测试用户")
    private String nickName;

    @ApiModelProperty(value = "会员性别(0-未知,1-男,2-女)", example = "1")
    private Integer sex;

    @DateTimeFormat(pattern = "yyyy-MM-dd")
    @ApiModelProperty(value = "会员生日", example = "1990-01-01")
    private Date birthday;

    @ApiModelProperty(value = "会员头像URL", example = "https://example.com/face.jpg")
    private String face;

    @ApiModelProperty(value = "客户端类型", example = "PC")
    private String clientEnum;
}